package db.pojo;

import java.util.*;
import java.text.SimpleDateFormat;
import db.ext.EauserauthorizeExt;
@SuppressWarnings("unchecked")
/**
 * eauserauthorize
 */
public class Eauserauthorize {
	/**
	 * AUTHORIZEID
	 */
	public String aUTHORIZEID;
	/**
	 * USERID
	 */
	public String uSERID;
	/**
	 * ROLEID
	 */
	public String rOLEID;
	SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
	public static EauserauthorizeExt DB = new EauserauthorizeExt(); 
	
	public Eauserauthorize() {
		super();
	}
	
	public Eauserauthorize(String aUTHORIZEID, String uSERID, String rOLEID) {
		super();
		this.aUTHORIZEID = aUTHORIZEID; 
		this.uSERID = uSERID; 
		this.rOLEID = rOLEID; 
	}
	
	public String getAUTHORIZEID() {
		return aUTHORIZEID;
	}

	public void setAUTHORIZEID(String aUTHORIZEID) {
		this.aUTHORIZEID = aUTHORIZEID;
	} 
	
	public String getUSERID() {
		return uSERID;
	}

	public void setUSERID(String uSERID) {
		this.uSERID = uSERID;
	} 
	
	public String getROLEID() {
		return rOLEID;
	}

	public void setROLEID(String rOLEID) {
		this.rOLEID = rOLEID;
	} 
	
	
	public Map eauserauthorizeToMap() {
		Map map = new HashMap();
		try {
			map.put("aUTHORIZEID",this.aUTHORIZEID);
			map.put("uSERID",this.uSERID);
			map.put("rOLEID",this.rOLEID);
		} catch (Exception e) {
			e.printStackTrace();
		}
		return map;
	}

	public Eauserauthorize mapToEauserauthorize(Map map){
		try {
			String aUTHORIZEID =  map.get("aUTHORIZEID").toString();
			String uSERID =  map.get("uSERID").toString();
			String rOLEID =  map.get("rOLEID").toString();
			Eauserauthorize eauserauthorize = new Eauserauthorize(aUTHORIZEID, uSERID, rOLEID);
			return eauserauthorize;
		} catch (Exception e) {
			e.printStackTrace();
			return null;
		}
	} 
	
	public String toString(){
		return eauserauthorizeToMap().toString();
	}
	
	//方便数据操作	
	public Eauserauthorize insert(){
		return DB.insert(this);
	}
	public Eauserauthorize update(){
		return DB.update(this);
	}
	
	public int delete(){
		return DB.delete(this);
	}
	
}
